program number2;

{$APPTYPE CONSOLE}

uses
  SysUtils;

var
  F, G, G1, r, R1, xo, x, yo, x1, y1: integer;
 a, b, c, c1, C2, C3, a1, A2, A3, B3, B2, b1:real;
begin
readln(r);
READLN(R1);
readln(xo);
readln(yo);
readln(x1);
readln(y1);
G:=R1+R;
G1:=R-R1;
f:=(x1-xo);
x:=(Y1-Yo);
a:=(G*F+x*(sqrt(f*f+x*x-G*G)))/(f*f+x*x);
a1:=(G*F-x*(sqrt(f*f+x*x-G*G)))/(f*f+x*x);
b:=(G*x-F*(sqrt(f*f+x*x-G*G)))/(f*f+x*x);
b1:=(G*x+F*(sqrt(f*f+x*x-G*G)))/(f*f+x*x);
c:=-(b*yo)-(a*xo)+R1;
c1:=-(b1*yO)-(a1*xO)+R1;
a2:=(G1*F+x*(sqrt(f*f+x*x-G1*G1)))/(f*f+x*x);
a3:=(G1*F-x*(sqrt(f*f+x*x-G1*G1)))/(f*f+x*x);
b2:=(G1*x-F*(sqrt(f*f+x*x-G1*G1)))/(f*f+x*x);
b3:=(G1*x+F*(sqrt(f*f+x*x-G1*G1)))/(f*f+x*x);
c2:=-(b*yo)-(a*xo)-R1;
c3:=-(b1*yO)-(a1*xO)-R1;
writeln('1)');
write('A1= ');
WRITELN(A1:0:3);
write('B1= ');
WRITELN(B1:0:3);
write('C1= ');
WRITELN(C1:0:3);
writeln('2)');
write('A= ');
WRITELN(A:0:3);
write('B= ');
WRITELN(B:0:3);
write('C= ');
WRITELN(C:0:3);;
writeln('3)');
write('A2= ');
WRITELN(A2:0:3);
write('B2= ');
WRITELN(B2:0:3);
write('C2= ');
WRITELN(C2:0:3);;
writeln('4)');
write('A3= ');
WRITELN(A3:0:3);
write('B3= ');
WRITELN(B3:0:3);
write('C3= ');
WRITELN(C3:0:3);;
readln;

end.
